package com.zjj.concurrent.thread;

/**
 * @author zhanglei.zjj
 * @description 使用Runnable接口将线程和任务分开 这种方式创建线程
 * @date 2023/5/14 21:56
 */
public class TestThreadUseRunnable {
    public static void main(String[] args) {
        Runnable runnable = new Runnable() {
            @Override
            public void run() {
                System.out.println("线程任务开始执行-runnable");
            }
        };
        Thread thread = new Thread(runnable);
        thread.start();
    }
}
